package com.wskj.common.utils.tencent.bean;

import lombok.Data;

import java.io.Serializable;
import java.util.List;
import java.util.Map;

/**
 * IM 回调时传过来的对象
 *
 * @author Gun
 * @date 2021/10/11
 */
@Data
public class ImApiRequest implements Serializable {

    private static final long serialVersionUID = 1L;

    private String CallbackCommand;
    private String GroupId;
    private String Type;
    private String JoinType;
    private String Operator_Account;
    private List<Map<String, Object>> NewMemberList;
    private List<MsgBody> MsgBody;
    private InfoBody Info;

    public class MsgBody {
        private String MsgType;
        private String MsgContent;

        public String getMsgType() {
            return MsgType;
        }

        public void setMsgType(String msgType) {
            MsgType = msgType;
        }

        public String getMsgContent() {
            return MsgContent;
        }

        public void setMsgContent(String msgContent) {
            MsgContent = msgContent;
        }
    }

    @Data
    public class InfoBody {
        // 用户上线或者下线的动作，Login 表示上线（TCP 建立），Logout 表示下线（TCP 断开），Disconnect 表示网络断开（TCP 断开）
        private String Action;
        private String To_Account;
        private String Reason;
    }

}
